import Vue from 'vue'
import Router from 'vue-router'
import mine from '@/pages/mine'
import takeout from '@/pages/takeout'
import discover from '@/pages/discover'
import orderform from '@/pages/orderform'
import dly from '@/pages/dly'
import mimadl from '@/pages/mimadl'
import pungent from '@/pages/pungent'
import meis from '@/pages/meis'
import edit from '@/pages/secondary/edit'
import denglu from '@/pages/secondary/denglu'
import home from '@/pages/secondary/home'


Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      name:'takeout',
      component: takeout
    },
    {
      path: '/mine',
      name: 'mine',
      component: mine
    },
    {
      path: '/discover',
      name: 'discover',
      component: discover,
    },
    {
      path: '/orderform',
      name: 'orderform',
      component: orderform
    },
    {
      path: '/dly',
      name: 'dly',
      component: dly,
      children:[
        {
          path: '',
          name: 'denglu',
          component: denglu, 
        }
      ] 
    },
    {
      path: '/pungent',
      name: 'pungent',
      component: pungent
    },
    {
      path: '/mimadl',
      name: 'mimadl',
      component: mimadl
    },
    {
      path: '/meis',
      name: 'meis',
      component: meis,
      children: [
        {
          path: '/home',
          name: '/home',
          component: home,
        },
        {
          path: '/edit',
          name: '/edit',
          component: edit, 
        }
      ]  
    }
  ]
})
